package cn.iocoder.yudao.module.call.dal.mysql.taskcalleelistnumberrule;

import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
import cn.iocoder.yudao.module.call.dal.dataobject.taskcalleelistnumberrule.TaskCalleeListNumberRuleDO;
import org.apache.ibatis.annotations.Mapper;
//import cn.iocoder.yudao.module.call.controller.admin.taskcalleelistnumberrule.vo.*;
import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
import cn.iocoder.yudao.module.call.dal.dataobject.taskcalleelistnumberrule.TaskCalleeListNumberRuleDO;
import org.apache.ibatis.annotations.Mapper;
import cn.iocoder.yudao.module.call.controller.admin.taskcalleelistnumberrule.vo.*;

/**
 * 呼叫名单号码额外参数规则 Mapper
 *
 * @author 数创万维
 */
@Mapper
public interface TaskCalleeListNumberRuleMapper extends BaseMapperX<TaskCalleeListNumberRuleDO> {

//    default PageResult<TaskCalleeListNumberRuleDO> selectPage(TaskCalleeListNumberRulePageReqVO reqVO) {
//        return selectPage(reqVO, new LambdaQueryWrapperX<TaskCalleeListNumberRuleDO>()
//                .eqIfPresent(TaskCalleeListNumberRuleDO::getExtendCode, reqVO.getExtendCode())
//                .likeIfPresent(TaskCalleeListNumberRuleDO::getExtendName, reqVO.getExtendName())
//                .betweenIfPresent(TaskCalleeListNumberRuleDO::getCreateTime, reqVO.getCreateTime())
//                .orderByDesc(TaskCalleeListNumberRuleDO::getId));
//    }
    default PageResult<TaskCalleeListNumberRuleDO> selectPage(TaskCalleeListNumberRulePageReqVO reqVO) {
        return selectPage(reqVO, new LambdaQueryWrapperX<TaskCalleeListNumberRuleDO>()
                .eqIfPresent(TaskCalleeListNumberRuleDO::getExtendCode, reqVO.getExtendCode())
                .likeIfPresent(TaskCalleeListNumberRuleDO::getExtendName, reqVO.getExtendName())
                .betweenIfPresent(TaskCalleeListNumberRuleDO::getCreateTime, reqVO.getCreateTime())
                .orderByDesc(TaskCalleeListNumberRuleDO::getId));
    }

}